import { IFeidaoAiBrowserComponent } from '@dfeidao/atom-web/interfaces';
import set from '@dfeidao/atom-web/local/set';
import s_get from '@dfeidao/atom-web/storage/get';

import nodejs from '@dfeidao/atom-web/msg/nodejs';
import render from '@dfeidao/atom-web/render/render';
// import show from '../../atom-web/show';
import p001 from './p001';
export default async function a001(fd: IFeidaoAiBrowserComponent) {
	//  调用事件
	fd.data.node.classList.remove('display-n');

	const prid = await s_get('productid');
	set(fd, 'productid', prid);
	const query = {
		filter: { productid: prid }
	};
	// const res = await nodejs<{ dataArray: object[] }>(url, './permissions/role_type_find1', query, false, false);
	const res = await nodejs<{ dataArray: object[] }>('role-type/zj-000002/s001', query);
	render(fd, res.dataArray, p001, 'p001', 'inner');
}
